-- GENERATED SPELL FOR [Akama] --


function spell0_23191(pUnit, Event) --@Chain Lightning,n/a--
pUnit:FullCastSpellOnTarget(39945,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_23191', 3000, 1)
end

function spell1_23191(pUnit, Event) --@Destructive Poison,n/a--
pUnit:FullCastSpellOnTarget(40874,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_23191', 620, 1)
end

function spell2_23191(pUnit, Event) --@Stealth,Self--
pUnit:FullCastSpellOnTarget(34189,pUnit)
pUnit:RegisterEvent('Sorts_23191', 547, 1)
end

function Sorts_23191(pUnit, Event)
local choix_sorts_23191 = math.random(0, 2)
if choix_sorts_23191 == 0 then
pUnit:RegisterEvent('spell0_23191', 1, 1)
end
if choix_sorts_23191 == 1 then
pUnit:RegisterEvent('spell1_23191', 1, 1)
end
if choix_sorts_23191 == 2 then
pUnit:RegisterEvent('spell2_23191', 1, 1)
end
end

function mob23191_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_23191', math.random(1500, 3000), 1)
end

function mob23191_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob23191_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob23191_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(23191, 1, 'mob23191_Action')
RegisterUnitEvent(23191, 2, 'mob23191_Leave')
RegisterUnitEvent(23191, 3, 'mob23191_Kill')
RegisterUnitEvent(23191, 4, 'mob23191_Die')
